package com.liwei.baselib;

import android.app.Application;
import android.content.Context;


/**
 * Created by Administrator on 2018/1/12.
 */

public class MyApplication extends Application {
    /**
     * 对外提供整个应用生命周期的Context
     **/
    private static Context instance;

    @Override
    public void onCreate() {
        super.onCreate();
        instance = this;
    }

    /**
     * 对外提供Application Context
     *
     * @return
     */
    public static Context gainContext() {
        return instance;
    }
}
